package com.qianniu.napi.admin.entity;

import com.baomidou.mybatisplus.enums.IdType;

import java.lang.reflect.Array;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableName;
import com.google.common.base.Strings;

import java.io.Serializable;
import java.util.List;

/**
 * <p>
 * 用户信息表
 * </p>
 *
 * @author chenxuebin
 * @since 2018-09-05
 */
@TableName("t_user")
public class User extends Model<User> {

	private static final long serialVersionUID = 1L;

	@TableId(value="id", type= IdType.AUTO)
	private Long id;

	/**
	 * 登陆账户
	 */
	private String username;
	/**
	 * 真实姓名
	 */
	private String name;
	/**
	 * openid
	 */
	private String openid;
	/**
	 * 联合id
	 */
	private String unionid;
	/**
	 * 昵称
	 */
	@TableField("nick_name")
	private String nickName;
	/**
	 * 图像
	 */
	@TableField("avatar_pic")
	private String avatarPic;
	/**
	 * 性别
	 */
	private String gender;
	/**
	 * 城市
	 */
	private String city;
	/**
	 * 省
	 */
	private String province;
	/**
	 * 县城
	 */
	private String country;
	/**
	 * 语言
	 */
	private String language;
	/**
	 * 密码
	 */
	private String password;
	/**
	 * 加密盐值
	 */
	private String salt;
	/**
	 * 公司名称
	 */
//	private String company;
//	private String gslogo;
//	private String depart;
//	private String qq;
//	private String industry;
	/**
	 * 职位
	 */
//	private String duty;
//	private String zhichen;

	private String addr;
	private String address;

	/**
	 * 是否商户用户
	 */
	@TableField("is_mch")
	private Integer isMch;

	/**
	 * 是否商户用户
	 */
	@TableField("is_platform")
	private Integer isPlatform;

	/**
	 * 是否代理用户
	 */
	@TableField("is_agent")
	private Integer isAgent;

	@TableField("is_admin")
	private Integer isAdmin;

	@TableField("is_focus")
	private Integer isFocus;

	@TableField("is_staff")
	private Integer isStaff;

	@TableField("is_oem")
	private Integer isOem;

	@TableField("is_waimai")
	private Integer isWaimai;
	@TableField("is_factory")
	private Integer isFactory;

	private Integer views;

	/**
	 * 手机号
	 */
	private String phone;
	private String photo;

//	private String skill;
//	private String resource;

	private String paypasswd;
	/**
	 * 座机电话
	 */
	private String telphone;
	/**
	 * 邮箱
	 */
	private String email;
	private String ip;
	/**
	 * 微信
	 */
	private String weixin;

	private String guid;

	/**
	 * 原始基因链#永久式原始的上下基因链，不因改变关系而改变
	 */
	private String genlink;

	/**
	 * 微博
	 */
//	private String weibo;

	@TableField(exist = false)
	private List<Role> roleList;

	@TableField(exist = false)
	private Boolean newuser;

	@TableField(exist = false)
	private List<String> perNameSet;

	@TableField(exist = false)
	private List<String> gphotosList;

	@TableField(exist = false)
	private Store store;

//	private String gs;
	private Integer age;
	private Integer sex;
	@TableField(exist = false)
	private String duty;
	@TableField(exist = false)
	private String workhour;
	private String tags;

	/**
	 * 当前积分
	 */
	private Integer jifen;
	/**
	 * 是否会员
	 */
	@TableField("is_member")
	private Integer isMember;

	@TableField("is_huoyue")
	private Integer isHuoyue;

	@TableField("has_callfunc")
	private Integer hasCallfunc;

	private String  callpwd;

	private Integer hasmp;

//	private Integer beiso;// 允许被搜索
//	private Integer gongkai;//所有信息都公开
//	private String mpimg;//背景图
//	private String mpclass;//样式
//	private Integer mptype;//种类

	/**
	 * 是否手机注册
	 */
//	@TableField("is_regist")
//	private Integer isRegist;

	/**
	 * 会员级别
	 */
	@TableField("member_level")
	private Integer memberLevel;

	/**
	 * 会员折扣#会员折扣，默认1=无折扣
	 */
	private BigDecimal discount;

	/**
	 * 是否支持会员卡现金业务#是否支持会员卡现金业务
	 */
	@TableField("is_ecash_card")
	private Integer isEcashCard;

	/**
	 * 是否启用
	 */
	private Integer state;
	/**
	 * 来源方式@0：自行注册；1：海报连接；2：激活码
	 */
	@TableField("origin_type")
	private Integer originType;
	/**
	 * 用户类型@0：试用用户；1：单店管理员；2：总店管理员；3：代理用户；4：运营人员；5：测试人员；9：超级管理员&
	 */
	@TableField("user_type")
	private Integer userType;
	/**
	 * 系统类型@1：微信公众号；2：微信小程序；3：微信商城；4：微信app；5：支付宝小程序；6：百度小程序
	 */
	private Integer apptype;
	/**
	 * 版本控制#版本控制，防止并发控制
	 */
	private Integer version;
	/**
	 * 备注
	 */
	private String remark;

//	private String gids;
//	private String gphotos;
//	private String vedio;
//	private String hangye;//同一个身份只能一个行业
//	private Integer hangyeid;//同一个身份只能一个行业
//	private String weixinimg;
//	private String audio;
//	private String signature;

	private Double latitude;
	private Double longitude;
	private String location;
	private String ud;

	private Date starttime;
	private Date endtime;

	private String brand;
	private String model;
	private String platform;
	private String system;
	private String sysversion;

	private BigDecimal xing;
//	private String sp;
	private Long mid;
	private Long mpid;
	private Long asmpid;
	private Long sid;
	private Long subsid;

	private String cardno;
	private String carda;
	private String cardb;

//	private String shengcode;
//	private String sheng;
//	private String shicode;
//	private String shi;
//	private String xiangcode;
//	private String xiang;

	/**
	 * 订阅时间
	 */
	@TableField("subscribe_time")
	private Long subscribeTime;
	private Date createtime;
	private Date modifytime;
	private Long modifier;


	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getOpenid() {
		return openid;
	}

	public void setOpenid(String openid) {
		this.openid = openid;
	}

	public String getUnionid() {
		return unionid;
	}

	public void setUnionid(String unionid) {
		this.unionid = unionid;
	}

	public String getNickName() {
		return nickName;
	}

	public void setNickName(String nickName) {
		this.nickName = nickName;
	}

	public String getAvatarPic() {
		return avatarPic;
	}

	public void setAvatarPic(String avatarPic) {
		this.avatarPic = avatarPic;
	}

	public String getGender() {
		return gender;
	}

	public void setGender(String gender) {
		this.gender = gender;
	}

	public String getCity() {
		return city;
	}

	public void setCity(String city) {
		this.city = city;
	}

	public String getProvince() {
		return province;
	}

	public void setProvince(String province) {
		this.province = province;
	}

	public String getCountry() {
		return country;
	}

	public void setCountry(String country) {
		this.country = country;
	}

	public String getLanguage() {
		return language;
	}

	public void setLanguage(String language) {
		this.language = language;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getSalt() {
		return salt;
	}

	public void setSalt(String salt) {
		this.salt = salt;
	}

	public String getAddr() {
		return addr;
	}

	public void setAddr(String addr) {
		this.addr = addr;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getPaypasswd() {
		return paypasswd;
	}

	public void setPaypasswd(String paypasswd) {
		this.paypasswd = paypasswd;
	}

	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public String getTelphone() {
		return telphone;
	}

	public void setTelphone(String telphone) {
		this.telphone = telphone;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getWeixin() {
		return weixin;
	}

	public void setWeixin(String weixin) {
		this.weixin = weixin;
	}

	public Integer getJifen() {
		return jifen;
	}

	public void setJifen(Integer jifen) {
		this.jifen = jifen;
	}

	public Integer getIsMember() {
		return isMember;
	}

	public void setIsMember(Integer isMember) {
		this.isMember = isMember;
	}

	public Integer getMemberLevel() {
		return memberLevel;
	}

	public void setMemberLevel(Integer memberLevel) {
		this.memberLevel = memberLevel;
	}

	public BigDecimal getDiscount() {
		return discount;
	}

	public void setDiscount(BigDecimal discount) {
		this.discount = discount;
	}

	public Integer getIsEcashCard() {
		return isEcashCard;
	}

	public void setIsEcashCard(Integer isEcashCard) {
		this.isEcashCard = isEcashCard;
	}

	public String getGuid() {
		return guid;
	}

	public void setGuid(String guid) {
		this.guid = guid;
	}

	public Integer getState() {
		return state;
	}

	public void setState(Integer state) {
		this.state = state;
	}

	public Integer getOriginType() {
		return originType;
	}

	public void setOriginType(Integer originType) {
		this.originType = originType;
	}

	public Integer getUserType() {
		return userType;
	}

	public void setUserType(Integer userType) {
		this.userType = userType;
	}

	public Integer getApptype() {
		return apptype;
	}

	public void setApptype(Integer apptype) {
		this.apptype = apptype;
	}

	public Integer getVersion() {
		return version;
	}

	public void setVersion(Integer version) {
		this.version = version;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public String getIp() {
		return ip;
	}

	public void setIp(String ip) {
		this.ip = ip;
	}

	public Integer getIsMch() {
		return isMch;
	}

	public void setIsMch(Integer isMch) {
		this.isMch = isMch;
	}

	public Integer getIsHuoyue() {
		return isHuoyue;
	}

	public void setIsHuoyue(Integer isHuoyue) {
		this.isHuoyue = isHuoyue;
	}

	public Integer getHasmp() {
		return hasmp;
	}

	public void setHasmp(Integer hasmp) {
		this.hasmp = hasmp;
	}

	public String getPhoto() {
		return photo;
	}

	public void setPhoto(String photo) {
		this.photo = photo;
	}

	public Double getLatitude() {
		return latitude;
	}

	public void setLatitude(Double latitude) {
		this.latitude = latitude;
	}

	public Double getLongitude() {
		return longitude;
	}

	public void setLongitude(Double longitude) {
		this.longitude = longitude;
	}

	public Long getMid() {
		return mid;
	}

	public void setMid(Long mid) {
		this.mid = mid;
	}

	public Long getMpid() {
		return mpid;
	}

	public void setMpid(Long mpid) {
		this.mpid = mpid;
	}

	public Long getSubscribeTime() {
		return subscribeTime;
	}

	public void setSubscribeTime(Long subscribeTime) {
		this.subscribeTime = subscribeTime;
	}

	public Integer getHasCallfunc() {
		return hasCallfunc;
	}

	public void setHasCallfunc(Integer hasCallfunc) {
		this.hasCallfunc = hasCallfunc;
	}

	public Date getCreatetime() {
		return createtime;
	}

	public void setCreatetime(Date createtime) {
		this.createtime = createtime;
	}

	public Date getModifytime() {
		return modifytime;
	}

	public void setModifytime(Date modifytime) {
		this.modifytime = modifytime;
	}

	public Long getModifier() {
		return modifier;
	}

	public void setModifier(Long modifier) {
		this.modifier = modifier;
	}

	public List<Role> getRoleList() {
		return roleList;
	}

	public void setRoleList(List<Role> roleList) {
		this.roleList = roleList;
	}

	public Long getSid() {
		return sid;
	}

	public void setSid(Long sid) {
		this.sid = sid;
	}

	public Integer getIsPlatform() {
		return isPlatform;
	}

	public void setIsPlatform(Integer isPlatform) {
		this.isPlatform = isPlatform;
	}

	public Integer getIsAgent() {
		return isAgent;
	}

	public void setIsAgent(Integer isAgent) {
		this.isAgent = isAgent;
	}

	public String getCallpwd() {
		return callpwd;
	}

	public void setCallpwd(String callpwd) {
		this.callpwd = callpwd;
	}

	public Long getSubsid() {
		return subsid;
	}

	public void setSubsid(Long subsid) {
		this.subsid = subsid;
	}

	public Store getStore() {
		return store;
	}

	public void setStore(Store store) {
		this.store = store;
	}

	public Boolean getNewuser() {
		return newuser;
	}

	public void setNewuser(Boolean newuser) {
		this.newuser = newuser;
	}

	public Integer getIsFocus() {
		return isFocus;
	}

	public void setIsFocus(Integer isFocus) {
		this.isFocus = isFocus;
	}

	public String getLocation() {
		return location;
	}

	public void setLocation(String location) {
		this.location = location;
	}

	public String getUd() {
		return ud;
	}

	public void setUd(String ud) {
		this.ud = ud;
	}

	public String getBrand() {
		return brand;
	}

	public void setBrand(String brand) {
		this.brand = brand;
	}

	public String getModel() {
		return model;
	}

	public void setModel(String model) {
		this.model = model;
	}

	public String getPlatform() {
		return platform;
	}

	public void setPlatform(String platform) {
		this.platform = platform;
	}

	public String getSystem() {
		return system;
	}

	public void setSystem(String system) {
		this.system = system;
	}

	public String getSysversion() {
		return sysversion;
	}

	public void setSysversion(String sysversion) {
		this.sysversion = sysversion;
	}

	public Integer getIsAdmin() {
		return isAdmin;
	}

	public void setIsAdmin(Integer isAdmin) {
		this.isAdmin = isAdmin;
	}

	public Long getAsmpid() {
		return asmpid;
	}

	public void setAsmpid(Long asmpid) {
		this.asmpid = asmpid;
	}

	public Integer getIsStaff() {
		return isStaff;
	}

	public void setIsStaff(Integer isStaff) {
		this.isStaff = isStaff;
	}

	public Integer getIsOem() {
		return isOem;
	}

	public void setIsOem(Integer isOem) {
		this.isOem = isOem;
	}

	public BigDecimal getXing() {
		return xing;
	}

	public void setXing(BigDecimal xing) {
		this.xing = xing;
	}

	public Date getStarttime() {
		return starttime;
	}

	public void setStarttime(Date starttime) {
		this.starttime = starttime;
	}

	public Date getEndtime() {
		return endtime;
	}

	public void setEndtime(Date endtime) {
		this.endtime = endtime;
	}

	public Integer getIsWaimai() {
		return isWaimai;
	}

	public void setIsWaimai(Integer isWaimai) {
		this.isWaimai = isWaimai;
	}

	public Integer getIsFactory() {
		return isFactory;
	}

	public void setIsFactory(Integer isFactory) {
		this.isFactory = isFactory;
	}

	public String getCardno() {
		return cardno;
	}

	public void setCardno(String cardno) {
		this.cardno = cardno;
	}

	public String getCarda() {
		return carda;
	}

	public void setCarda(String carda) {
		this.carda = carda;
	}

	public String getCardb() {
		return cardb;
	}

	public void setCardb(String cardb) {
		this.cardb = cardb;
	}

	public Integer getAge() {
		return age;
	}

	public void setAge(Integer age) {
		this.age = age;
	}

	public Integer getSex() {
		return sex;
	}

	public void setSex(Integer sex) {
		this.sex = sex;
	}

	public String getGenlink() {
		return genlink;
	}

	public void setGenlink(String genlink) {
		this.genlink = genlink;
	}

	public String getDuty() {
		return duty;
	}

	public void setDuty(String duty) {
		this.duty = duty;
	}

	public String getTags() {
		return tags;
	}

	public void setTags(String tags) {
		this.tags = tags;
	}

	public String getWorkhour() {
		return workhour;
	}

	public void setWorkhour(String workhour) {
		this.workhour = workhour;
	}

	public Integer getViews() {
		return views;
	}

	public void setViews(Integer views) {
		this.views = views;
	}



	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	@Override
	public String toString() {
		return "User{" +
				"id=" + id +
				", username=" + username +
				", name=" + name +
				", openid=" + openid +
				", unionid=" + unionid +
				", nickName=" + nickName +
				", avatarPic=" + avatarPic +
				", gender=" + gender +
				", city=" + city +
				", province=" + province +
				", country=" + country +
				", language=" + language +
				", password=" + password +
				", salt=" + salt +
				", phone=" + phone +
				", telphone=" + telphone +
				", email=" + email +
				", weixin=" + weixin +
				", jifen=" + jifen +
				", isMember=" + isMember +
				", memberLevel=" + memberLevel +
				", discount=" + discount +
				", isEcashCard=" + isEcashCard +
				", state=" + state +
				", originType=" + originType +
				", userType=" + userType +
				", apptype=" + apptype +
				", version=" + version +
				", remark=" + remark +
				", mid=" + mid +
				", mpid=" + mpid +
				", subscribeTime=" + subscribeTime +
				", createtime=" + createtime +
				", modifytime=" + modifytime +
				", modifier=" + modifier +
				"}";
	}
}
